package snaptest.tool.ui;

public class SnapTestTool {

	public static void main(String[] args) {
		new SnapTestTool().show();
	}

	private SnapTestToolView view = new SnapTestToolView();

	private FileListingModel model = new FileListingModel();

	private void show() {
		bind();
		model.loadListing();
		view.show();
	}

	private void bind() {
		view.getFileList().setModel(model.getListModel());
		view.getFileList().setSelectionModel(model.getSelectionModel());
		
		view.getNewTextField().setDocument(model.getFileDiffModel().getNewDoc());
		view.getReferenceTextField().setDocument(model.getFileDiffModel().getRefDoc());
	}

}
